//units
#ifndef UNIT_H
#define UNIT_H
#include <string>
#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;

class Brigade
{
      public:
             
             Brigade::Brigade(int a, int b, int c){
                 m_number = a;
                 m_type = b;
                 }
             //get
             int Getnumber(){return m_number;};
             int Gettype(){return m_type;};
             /* 
             1:Inf
             2:Kav
             3:Art
             4:Wagon
             5:Civilians ( - maintenance)
             */
             int Getendurance(){return m_endurance;};
             int Getexp(){return m_exp;};
             // Used in list or not...
             
             //set
             void Setexp(int xp){m_exp = xp; return;};
             void Setnumber(int nr){m_number = nr; return;};
             void Settype(int type){m_type = type; return;};
             void Setendurance(int end){m_endurance = end; return;};
             //operations
             
      private:
              int m_number;
              int m_type;
              int m_endurance;
              int m_exp;
              };

class Army
{
      public:
             Army::Army(bool com = false, bool){
                            bool m_commander = com;
                            }
                            
                            int GetLocation(){return m_location;};
                            bool GetCommander(){return m_commander;};
                            int GetSupply(){return m_supply;};
                            string GetName(){return m_name;};
                                  
                            
                            void SetLocation(int);
                            void SetCommander(bool);
                            void SetSupply(int);
                            void SetName(string name){m_name = name;};
                            
                            void AddBrigade(const Brigade& newbrigade) { m_Brigades.push_back(newbrigade); };
                            
                            void RemoveBrigade(int nr){m_Brigades.erase(m_Brigades.begin()+nr);};
                            
                            void WipeBrigades(){m_Brigades.erase(m_Brigades.begin(), m_Brigades.end());};
                 
                            bool CheckEmpty(){m_Brigades.empty();};
      private:
              string m_name;
              int m_location;
              bool m_commander;
              int m_supply;
              vector<Brigade> m_Brigades;
};
      
#endif
